package com.apesource.mallproject.service.ServiceImpl;

import com.apesource.mallproject.dao.IAdDao;
import com.apesource.mallproject.pojo.Advertising;
import com.apesource.mallproject.service.IAdService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.math.BigInteger;
import java.util.List;

@Service
public class AdServiceImpl implements IAdService {
    @Autowired
    private IAdDao iAdDao;

    @Override
    public List<Advertising> queryAll() {
        return iAdDao.queryAll();
    }

    @Override
    public void insertAd(Advertising ad) {
        iAdDao.insertAd(ad);
    }

    @Override
    public void updateAd(Advertising ad) {
        iAdDao.updateAd(ad);
    }

    @Override
    public void delOne(BigInteger id) {
        iAdDao.delAd(id);
    }

    @Override
    public void batchDel(String[] ids) {
        iAdDao.batchDeleteAd(ids);
    }

}
